/**
 * User: kyleolivo
 * Date: 2/9/14
 * Time: 7:31 PM
 */
public class Triangle {

    private void printOneAsterisk() {
        System.out.println("*");
        System.out.println("----------");
    }

    private void printHorizontalLine(int asteriskCount) {
        for (int i = 0; i < asteriskCount; i++) {
            System.out.print("*");
        }
        System.out.println("\n----------");
    }

    private void printVerticalLine(int asteriskCount) {
        for (int i = 0; i < asteriskCount; i++) {
            System.out.println("*");
        }
        System.out.println("----------");
    }

    private void printTriangle(int asteriskCount) {
        for (int i = 0; i < asteriskCount; i++) {
            for (int j = 0; j < i + 1; j++) {
                System.out.print("*");
            }
            System.out.println();
        }
        System.out.println("----------");
    }

    public static void main(String[] args) {
        Triangle myTriangle = new Triangle();
        myTriangle.printOneAsterisk();
        myTriangle.printHorizontalLine(8);
        myTriangle.printVerticalLine(3);
        myTriangle.printTriangle(3);
    }
}
